package com.example.experiment4.service;

import com.example.experiment4.domain.Person;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class SaveExcel {
    @Resource
    ReadExcel excel;

    @Resource
    PersonService psvc;

    public String getAndSaveData(String pathname){
        List<Person> plist = excel.underFolder(pathname);
        return psvc.saveData(plist);
    }
}
